package lk.icta.common.dao;

import lk.icta.common.entity.Contacts;
import lk.icta.user.entity.User;

import java.util.List;

/**
 * @author Supun Nimesh Karunathilaka
 */
public interface ContactsDAO {

    /**
     * Add a new Contact
     *
     * @param contact contact to be marked
     * @param user    user executing the operation
     */
    public void addContacts(Contacts contact, User user);

    /**
     * Update a Contact
     *
     * @param contact contact to be updated
     * @param user    user executing the operation
     */
    public void updateContacts(Contacts contact, User user);

    /**
     * Deleting a Contact
     *
     * @param contacts Contact to be deleted
     * @param user     User requesting to delete the contact
     */
    public void deleteContact(Contacts contacts, User user);

    /**
     * get  a Contact by contact id
     *
     * @param id   The id of contact
     * @param user user executing the operation
     * @return Contacts corresponding to the given id
     */
    public Contacts getContactsByIdUKey(long id, User user);

    /**
     * Return all Contacts
     *
     * @return all Contacts
     */
    public List<Contacts> findAll();
}